<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<style>
      span{
      	padding: 5px;
      	border: 1px solid #000;
      	margin: 2px;
      }
    </style>
</head>
<body>
	<script>
        for(i=1;i<=9;i++){
            for(j=1;j<=i;j++){
                 document.write("<span>"+j+"x"+i+"="+j*i+"</span>");
            };
             document.write("<br>"+"<br>");
         };
	</script>
</body>
</html>












<!-- <!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<script>
        for (var i = 1; i <=9; i++) {
        	document.write(i);
        }
	</script>
</body>
</html> -->
























<!-- <!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>九九乘法表</title>
    <style>
        a{
            opacity: 0;
        }
        div{
            display: inline-block;
            width:60px;
            height:20px;
        }
        span{
            display: inline-block;
            width:60px;
            opacity: 0;
            height:20px;
        }
    </style>
</head>
<body style="width:800px;">
    <script>
         //九九乘法表
         //第一种
         //行
         for(var i=1;i<=9;i++){
            // 列
             for(var j=1;j<=i;j++){
                 document.write(i+"*"+j+"="+i*j+"<a>***</a>");
             }
             document.write("<br/>");
         }
         document.write("<hr/>");
 
         //第二种
         //行
         for(var i=9;i>=1;i--){
             for(var j=1;j<=i;j++){
                document.write(i+"*"+j+"="+i*j+"<a>***</a>");
             }
             document.write("<br/>");
         }
         document.write("<hr/>");
 
         //第三种
         //行
         for( var i=1;i<=9;i++ ){
             //打印空白
             for( var j=1;j<=9-i;j++ ){
                document.write("<span>"+i+"*"+j+"="+i*j+"</span>"+"<a>***</a>");
             }
              //打印乘法式子
             for( var k=1;k<=i;k++){
                document.write("<div>"+i+"*"+k+"="+i*k+"</div>"+"<a>***</a>");
             }
            document.write("<br/>");
         }
         document.write("<hr/>");
         
         //第四种
         //行
         for( var i=9;i>=1;i-- ){
             //打印空白
             for( var j=1;j<=9-i;j++ ){
                document.write("<span>"+i+"*"+j+"="+i*j+"</span>"+"<a>***</a>");
             } 
             //打印乘法式子
             for( var k=1;k<=i;k++){
                document.write("<div>"+i+"*"+k+"="+i*k+"</div>"+"<a>***</a>");
             }
            document.write("<br/>");
         }
         document.write("<hr/>");
    </script>
</body>
</html> -->